home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Language/OS - Multiplatform Resource Library
/
LANGUAGE OS.iso
/
lisp
/
elk-2_0.lha
/
elk-2.0
/
contrib
/
zelk
/
scm
/
countlines.e
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
Text File
|
1992-10-17
|
215 b
|
9 lines
;; countlines.e - return the # of lines in a file
(require 'shell.e)
(define (countlines file)
(let ((s (open-input-string (car (getoutput (string-append "wc " file))))))
(read s)
(close-input-port s))
)